Skip to content

fix: fully unwrap union aliases in mapped keys to avoid generating incorrect additionalProperties#2232

Merged
arthurfiorette merged 2 commits into
vega:nextfrom
alexchexes:fix/additional-properties-union-alias
May 16, 2025
Merged

fix: fully unwrap union aliases in mapped keys to avoid generating incorrect additionalProperties#2232
arthurfiorette merged 2 commits into
vega:nextfrom
alexchexes:fix/additional-properties-union-alias

Conversation

@alexchexes
Copy link
Copy Markdown
Contributor

@alexchexes alexchexes commented Apr 14, 2025

Closes #2231

Version

Published prerelease version: v2.4.1-next.1

Changelog

🎉 This release contains work from a new contributor! 🎉

Thank you, Alex (@alexchexes), for all your work!

🐛 Bug Fix

  • fix: fully unwrap union aliases in mapped keys to avoid generating incorrect additionalProperties #2232 (@alexchexes)
  • fix: avoid incorrect additionalProperties for Pick<..., AliasLiteralUnion> #2230 (@alexchexes)

🔩 Dependency Updates

Authors: 2

Copy link
Copy Markdown
Collaborator

@arthurfiorette arthurfiorette left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Comment thread test/valid-data/type-mapped-pick-union-alias/main.ts
Comment thread test/valid-data/type-mapped-pick-union-alias/main.ts
@arthurfiorette arthurfiorette self-assigned this May 16, 2025
@arthurfiorette
Copy link
Copy Markdown
Collaborator

Tested it locally and also worked as expected. Thanks!

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Feb 4, 2026

🚀 PR was released in v2.5.0 🚀

@github-actions github-actions Bot added released This issue/pull request has been released. and removed prerelease labels Feb 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

released This issue/pull request has been released.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Pick with union of unions of literals generates wrong additionalProperties.

3 participants